package com.shiguo365.market.display.activity;

import android.content.ContentValues;
import android.content.Intent;
import android.database.sqlite.SQLiteDatabase;
import android.os.Handler;
import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;
import android.support.v7.widget.Toolbar;
import android.util.Log;

import com.github.javiersantos.bottomdialogs.BottomDialog;
import com.shiguo365.market.R;
import com.shiguo365.market.application.MyApplication;
import com.shiguo365.market.display.base.BaseActivity;
import com.shiguo365.market.display.listener.NavigationFinishClickListener;
import com.shiguo365.market.display.util.ToastUtils;

import java.text.SimpleDateFormat;
import java.util.Date;

import butterknife.BindView;
import butterknife.ButterKnife;
import butterknife.OnClick;

public class SuggestionsActivity extends BaseActivity {

    private Handler mHandler = new Handler();



    @BindView(R.id.suggeestions_toolbar)
    protected Toolbar toolbar;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_suggestions);
        ButterKnife.bind(this);
        toolbar.setNavigationOnClickListener(new NavigationFinishClickListener(this));
    }

    @OnClick(R.id.buttonSuggestionsCommit)
    protected void btnCommit(){
//        Intent intent =new Intent(this,WebViewActivity.class);
//        intent.putExtra("url","http://ec.shiguo365.com/index.php?s=/home/article/detail/id/1.html");
//        startActivity(intent);

//        new BottomDialog.Builder(this)
//                .setTitle("Awesome!")
//                .setContent("What can we improve? Your feedback is always welcome.")
//                .show();

//        SQLiteDatabase db =MyApplication.getDbHelper().getWritableDatabase();
//        ContentValues values =new ContentValues();
//        values.put("notificationId","111111");
//        values.put("title","x");
//        values.put("content","xxxxxxxxxxx");
//        values.put("extras","");
//        SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
//        String time=sdf.format(new Date());
//        values.put("creatTime",time);
//
//        db.insert("Notification",null,values);
//
//        //ToastUtils.with(this).show("insert data success!");
//        db.close();
    }

}
